Skip to content

Conversation

4rthurmonteiro
Copy link
Contributor

@4rthurmonteiro 4rthurmonteiro commented Apr 15, 2025

Add support to camera control button on web.

Fixes flutter/flutter#167137

Pre-Review Checklist

If you need help, consider asking for advice on the #hackers-new channel on Discord.

Footnotes

  1. Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling. 2 3

@4rthurmonteiro 4rthurmonteiro marked this pull request as ready for review April 21, 2025 19:16
@stuartmorgan-g stuartmorgan-g added the triage-web Should be looked at in web triage label May 13, 2025
@mdebbar mdebbar requested a review from harryterkelsen June 11, 2025 18:09
Copy link
Contributor

@harryterkelsen harryterkelsen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your contribution! This PR looks good to me with a minor nit about improving doc comments. This is ready to split into separate PRs for landing

/// See [WebCameraControlPosition] for more details.
final WebCameraControlPosition? webCameraControlPosition;

/// This setting controls how the API handles cameraControl button on the map. Web only.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Have a more descriptive comment here. Something like "Enables or disables the Camera controls."

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done.

Copy link
Contributor

@harryterkelsen harryterkelsen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@@ -2,7 +2,7 @@ name: google_maps_flutter
description: A Flutter plugin for integrating Google Maps in iOS and Android applications.
repository: https://github.com/flutter/packages/tree/main/packages/google_maps_flutter/google_maps_flutter
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+maps%22
version: 2.12.1
version: 2.12.2
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As indicated in the PR checklist, we follow semver, which requires changing the minor version when adding public API.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All of the google_maps_flutter_android and google_maps_flutter_ios changes can be reverted.

@@ -1,3 +1,7 @@
## 2.11.2

* Adds support to camera control button on web.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"Adds support for disabling or moving the camera control button on web."

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done.

@@ -44,6 +46,16 @@ class MapConfiguration {
/// See [WebGestureHandling] for more details.
final WebGestureHandling? webGestureHandling;

/// This setting controls how the API handles cameraControl button position on the map. Web only.
///
/// See [WebCameraControlPosition] for more details.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same comment here; the null behavior should be documented.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done.

| LB RB |
| BL BC BR |
+----------------+
*/
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the purpose of duplicating this from the link below? It's not part of the doc comment, and the plugin will never be responsible for actually implementing this behavior, so it's not clear to me who the audience for this comment is.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good point. I removed the duplicated info.

@@ -4,7 +4,7 @@ repository: https://github.com/flutter/packages/tree/main/packages/google_maps_f
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+maps%22
# NOTE: We strongly prefer non-breaking changes, even at the expense of a
# less-clean API. See https://flutter.dev/go/platform-interface-breaking-changes
version: 2.11.1
version: 2.11.2
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same versioning note here.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done.

@stuartmorgan-g stuartmorgan-g removed the triage-web Should be looked at in web triage label Jun 12, 2025
@stuartmorgan-g
Copy link
Collaborator

@4rthurmonteiro Are you still planning on updating this based on the feedback above and then splitting out the first sub-PR?

@4rthurmonteiro
Copy link
Contributor Author

@4rthurmonteiro Are you still planning on updating this based on the feedback above and then splitting out the first sub-PR?

Hi @stuartmorgan-g yes!

auto-submit bot pushed a commit that referenced this pull request Aug 28, 2025
…able & position on web (#9897)

Platform interface portion of #9089.

Part of flutter/flutter#167137

## Pre-Review Checklist

**Note**: The Flutter team is currently trialing the use of [Gemini Code Assist for GitHub](https://developers.google.com/gemini-code-assist/docs/review-github-code). Comments from the `gemini-code-assist` bot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed.

[^1]: Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling.
@4rthurmonteiro
Copy link
Contributor Author

Hey @stuartmorgan-g and @harryterkelsen the platform web PR is here #9921

@vashworth vashworth removed their request for review August 28, 2025 21:44
auto-submit bot pushed a commit that referenced this pull request Sep 2, 2025
… on web (#9921)

Platform web portion of #9089.

Part of flutter/flutter#167137

## Pre-Review Checklist

**Note**: The Flutter team is currently trialing the use of [Gemini Code Assist for GitHub](https://developers.google.com/gemini-code-assist/docs/review-github-code). Comments from the `gemini-code-assist` bot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed.

[^1]: Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling.
@4rthurmonteiro
Copy link
Contributor Author

Hey @stuartmorgan-g & @harryterkelsen I updated the PR with new platform-interface version & web version.

Copy link
Collaborator

@stuartmorgan-g stuartmorgan-g left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@stuartmorgan-g stuartmorgan-g added the autosubmit Merge PR when tree becomes green via auto submit App label Sep 3, 2025
@auto-submit auto-submit bot merged commit dc48f5c into flutter:main Sep 3, 2025
80 checks passed
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Sep 3, 2025
github-merge-queue bot pushed a commit to flutter/flutter that referenced this pull request Sep 3, 2025
flutter/packages@5d785a0...42bb347

2025-09-03 [email protected] [google_maps_flutter] Fixes
exception when dispose is called while asynchronous update from
didUpdateWidget is executed (flutter/packages#9227)
2025-09-03 [email protected] [google_maps_flutter] Add
cameraControl enable/disable & position on web (flutter/packages#9089)
2025-09-03 [email protected] [tool] Only license-check checked-in
files (flutter/packages#9905)
2025-09-03 [email protected]
[interactive_media_ads] Fixes preloading ad while another was playing on
Android (flutter/packages#9904)
2025-09-02 [email protected] Update
FWFWebViewFlutterWKWebViewExternalAPITests.swift (flutter/packages#9922)
2025-09-02 [email protected] Update
Stubs for FlutterPluginRegistrar interface change
(flutter/packages#9923)
2025-09-02 [email protected]
[camera_android_camerax] Update Android minimum SDK version
(flutter/packages#9945)
2025-09-02 [email protected] Roll Flutter from
da5523a to 6b18740 (49 revisions) (flutter/packages#9926)
2025-09-02 [email protected] [various] Scrub pre-iOS-13 code
(flutter/packages#9849)
2025-09-02 [email protected] [google_maps_flutter_web] Add
cameraControl enable/disable & position on web (flutter/packages#9921)

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-packages-flutter-autoroll
Please CC [email protected] on the revert to ensure that a
human
is aware of the problem.

To file a bug in Flutter:
https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
autosubmit Merge PR when tree becomes green via auto submit App p: google_maps_flutter
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[google_maps_flutter][web] cameraControl enables/disables the camera control and allow change cameraControl position
3 participants